package com.nacos.test.impl;

import com.nacos.test.UserServcie;
import com.nacos.test.mapper.UserMapper;
import com.nacos.test.pojo.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 项目名称：nacos_parent
 * 类 名 称：UserServiceImpl
 * 类 描 述：TODO
 * 创建时间：2020/5/19
 * 创 建 人：Areli
 */
@Service
public class UserServiceImpl implements UserServcie {
    @Autowired
    private UserMapper userMapper;

    @Override
    public User queryUserByUserId(Long id) {
        return userMapper.selectByPrimaryKey(id);
    }

    @Override
    public List<User> queryAll() {
        return userMapper.selectAll();
    }
}
